home *** CD-ROM | disk | FTP | other *** search
- <!--- This example shows the use of REReplace --->
- <HTML>
- <HEAD>
- <TITLE>
- REReplace Example
- </TITLE>
- </HEAD>
-
- <BASEFONT FACE="Arial, Helvetica" SIZE=2>
- <BODY bgcolor="#FFFFD5">
- <H3>REReplace Example</H3>
-
- <P>The REReplace function returns <i>string</i> with a regular expression
- being replaced with <i>substring</i> in the specified scope.
- This is a case-sensitive search.
-
- <P>REReplace("CABARET","C|B","G","ALL"):
- <CFOUTPUT>#REReplace("CABARET","C|B","G","ALL")#</CFOUTPUT>
- <P>REReplace("CABARET","[A-Z]","G","ALL"):
- <CFOUTPUT>#REReplace("CABARET","[A-Z]","G","ALL")#</CFOUTPUT>
- <P>REReplace("I love jellies","jell(y|ies)","cookies"):
- <CFOUTPUT>#REReplace("I love jellies","jell(y|ies)","cookies")#</CFOUTPUT>
- <P>REReplace("I love jelly","jell(y|ies)","cookies"):
- <CFOUTPUT>#REReplace("I love jelly","jell(y|ies)","cookies")#</CFOUTPUT>
-
- </BODY>
- </HTML>
-